import { Controller, Get, Query, UsePipes } from '@nestjs/common';
import dtoValidationPipe from 'src/pipe/Dto.pipe';
import { ChargeOrderService } from './charge-order.service';
import ListDto from './dto';

@Controller('chargeOrder')
export class ChargeOrderController {
    constructor(
        private chargeOrderService:ChargeOrderService
    ){}
    @Get('list')
    @UsePipes(dtoValidationPipe({skipMissingProperties : true}))
    list(@Query() dto:ListDto) {
        return this.chargeOrderService.list(dto, 0)
    }
}
